'''
Created on Apr 22, 2012

@author: samindaw
'''
from net.pycbr.CBR import CBREngine, read_casebase

#load the casebase from the file.
cb=read_casebase("../resources/samples/animal_food.txt")

#instantiate the CBR engine
cbr=CBREngine(cb)

data = {"animal":"cow", "eat":"grass"}

print "Searching for "+str(data)+" ...",
results=cbr.search_case(data)
print "done"

for result in results: print str(result[0])+"\t: "+str(result[1]) 